package org.x.yuenovel.controller.param;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;

/**
 * @author xuezhendong
 * @date 2022/4/21 10:19 下午
 */
@Data
public class RegisterParam {

    /**
     * 验证码
     */
    @NotBlank(message = "验证码不能为空")
    private String captchaCode;

    @NotBlank(message = "用户名不能为空")
    @Length(min = 2, max = 20)
    private String username;

    @NotBlank(message = "密码不能为空")
    @Length(min = 6, max = 20)
    private String password;

    @Email
    private String mail;
}
